package study;


import org.apache.log4j.BasicConfigurator;
import org.apache.log4j.Level;
import org.apache.log4j.Logger;
import org.apache.log4j.PropertyConfigurator;

/**
 *
 * @author mayn
 */
public class HelloLogWorld {
    /**
     *
     */
    static final Logger logger = Logger.getLogger(HelloLogWorld.class);


    public static void main(String[] args) {
        //BasicConfigurator.configure();
        PropertyConfigurator.configure("D:\\IDEAProject\\test\\src\\main\\resources\\log4jconfig.properties");

        logger.setLevel(Level.DEBUG);
        // debug level
        logger.debug("This is debug level  log");
        // info level
        logger.info("This is info level log");
        // warning level
        logger.warn("This is warning level log");
        // error level
        logger.error("This is error level log");
    }
}